#define _CRT_SECURE_NO_WARNINGS 1
#include<stdio.h>
#include <stdbool.h>
bool Find(int target, int** array, int arrayRowLen, int arrayColLen) {
    int row = 0;
    int col =arrayColLen - 1;
    if (array == NULL || arrayRowLen <= 0 || arrayColLen <= 0)
        return false;
    while (row < arrayRowLen && col >= 0)
    {
        if (array[row][col] < target)
        {
            row++;
        }
        else if (array[row][col] > target)
        {
            col--;
        }
        else
        {
            return true;
        }
    }
    return false;
}

